﻿@model MvcFlaschi.Models.Flaschi

@{
    ViewBag.Title = "Edit";
    
    var fDateAttr = new Dictionary<string, object>();
    fDateAttr.Add("type", "date");
    var fTimeAttr = new Dictionary<string, object>();
    fTimeAttr.Add("type", "time");
    //fDateAttr.Add("data-options", "{\"mode\":\"flipbox\", \"useNewStyle\":true}");
    //fDateAttr.Add("data-role","datebox");
        
}
@section headerbar{
    <a href="@Url.Action("Index")" data-icon="arrow-l">Zurück</a>
}
@using (Html.BeginForm())
{
    @Html.AntiForgeryToken()
    @Html.ValidationSummary(true)

    <fieldset>
        <legend class="hidden">Bearbeiten</legend>
        @Html.HiddenFor(model => model.FlaschiId)
        @*        <a href="@Url.Action("Index")" title="Zurück">
            <span class="glyphicon glyphicon-chevron-left">Zurück</span>
        </a>*@
        <div class="input-fields">
            <div>
                @Html.LabelFor(model => model.FlaschiMenge)
            </div>
            <div>
                @Html.EditorFor(model => model.FlaschiMenge)
                @Html.ValidationMessageFor(model => model.FlaschiMenge)
            </div>

            <div>
                @Html.LabelFor(model => model.FlaschiDate)
            </div>
            <div>
                @*@Html.EditorFor(model => model.FlaschiDate)*@
                @Html.TextBoxFor(model => model.FlaschiDate, fDateAttr)
                @Html.ValidationMessageFor(model => model.FlaschiDate)
            </div>

            <div>
                @Html.LabelFor(model => model.FlaschiTime)
            </div>
            <div>
                @*@Html.EditorFor(model => model.FlaschiTime)*@
                @Html.TextBoxFor(model => model.FlaschiTime, fTimeAttr)
                @Html.ValidationMessageFor(model => model.FlaschiTime)
            </div>
        </div>
        @*        <button type="submit" class="btn btn-default btn-default">
            <span class="glyphicon glyphicon-floppy-disk"></span>Speichern
        </button>*@
    </fieldset>
}
@section footerbar {
    @*    <a href="@Url.Action("Index")" data-icon="delete">Abbrechen</a>
    <a href="@Url.Action("Index")" data-icon="trash" id="edit-mobile-delete" data-iconpos="notext">&nbsp;</a>
    <a href="@Url.Action("Index")" data-icon="check" id="edit-mobile-save" data-iconpos="right">Speichern</a>*@
    <div data-role="navbar">
        <ul>
            <li><a href="@Url.Action("Index")" data-icon="delete">Abbrechen</a></li>
            <li><a href="#" data-icon="trash" id="edit-mobile-delete">Löschen</a></li>
            <li><a href="#" data-icon="check" id="edit-mobile-save" data-iconpos="right">Speichern</a></li>
        </ul>
    </div>
}
@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
    @*@Scripts.Render("~/bundles/jqueryui")*@

    <script src="~/Scripts/edit-mobile.js"></script>
}
